package com.itheima.service;

import com.itheima.businessException.AddException;
import com.itheima.businessException.DeleteException;
import com.itheima.businessException.FindException;
import com.itheima.businessException.UpdateException;
import com.itheima.entity.PageResult;
import com.itheima.entity.QueryPageBean;
import com.itheima.pojo.CheckItem;

import java.util.List;

/**
 * @author LiangTianQi
 * @describe 检查项目的接口
 * @date 2020/11/8 15:01
 */
public interface CheckItemSevice {
    /**
     * 新增检查项目
     * @param checkItem
     * @return
     */
    public abstract boolean add(CheckItem checkItem) throws AddException;

    /**
     * 删除
     * @param id
     * @return
     */
    boolean delete(Integer id) throws DeleteException;

    /**
     * 更新
     * @param checkItem
     * @return
     */
    boolean update(CheckItem checkItem) throws UpdateException;

    /**
     * 通过id查询
     *
     * @param id
     * @return
     */
    CheckItem get(Integer id) throws FindException;

    /**
     * 通过条件查询
     * @param queryPageBean
     * @return
     */
    PageResult getByConditions(QueryPageBean queryPageBean) throws FindException;


    /**
     * 查询全部数据
     * @return
     */
    List<CheckItem> getAll() throws FindException;
}
